import React,{Component} from "react"

import{
    Image,
    Text,
    View,
    StyleSheet,
    Dimensions,
    TouchableHighlight
}from 'react-native'


const { width, height } = Dimensions.get('window');

const uiwidth=(width-30)/2

const styles=StyleSheet.create({
     warp:{
         width:'100%',
         padding:15,
         backgroundColor:'white',
         flexDirection:'row',
         justifyContent:'space-around',
         flexWrap:'wrap'
     },
     singui:{
         width:uiwidth,
         paddingTop:30,
         flexDirection:'column',
         alignItems:'center'
     },
     imgui:{
         width:'80%',
         height:40
     }
})

export default class Foodsetwarp extends Component{
    static navigationOptions={
        title:'菜品设置',
        headerTitleStyle: {
        alignSelf:'center'
      },
    };


    render(){
        return(
            <View style={styles.warp}>
            <TouchableHighlight  onPress={()=>this.props.navigation.navigate("FoodType")}>
            <View style={styles.singui}>
            <Image 
            style={styles.imgui}
            resizeMode='contain'
            source={require('../../img/editor.png')}/>
            <Text>菜类设置</Text>
            </View>
            </TouchableHighlight>

            <TouchableHighlight onPress={()=>this.props.navigation.navigate("Foodgood")}>
            <View style={styles.singui}>
            <Image 
            style={styles.imgui}
            resizeMode='contain'
            source={require('../../img/editor.png')}/>
            <Text>菜品设置</Text>
            </View>
            </TouchableHighlight>

            <TouchableHighlight  onPress={()=>this.props.navigation.navigate("FoodGuige")}>
            <View style={styles.singui}>
            <Image 
            style={styles.imgui}
            resizeMode='contain'
            source={require('../../img/editor.png')}/>
            <Text>规格设置</Text>
            </View>
            </TouchableHighlight>

            <TouchableHighlight>
            <View style={styles.singui}>
            <Image 
            style={styles.imgui}
            resizeMode='contain'
            source={require('../../img/editor.png')}/>
            <Text>上下架</Text>
            </View>
            </TouchableHighlight>
            </View>
        )
    }
}